#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <ctype.h>

int line_num = 0;
int pre_process(){
    char pre, now, next;
    int state = 0;
    while(1){
        if(!state){
             now = getchar();
             if(now == EOF) break;
        }else{
            now = next;
        }
        if(now == '/'){
            next = getchar();
            if(next == '*'){
                while(!(now == '*' && next == '/')){
                    now = next;
                    next = getchar();
                }
            }
            else if(next == '/'){
                while(!(next == '\n')){
                    next = getchar();
                }
            }
            else{
                state = 1;
                putchar(now);
            }
        }
        else if(now == '\t' || now == '\r'){
        }
        else if(now == '\n'){
            putchar(' ');
            line_num++;
        }
        else if(now == ' '){
            while(1){
                next = getchar();
                if( isspace(next) == 0) {
                     state = 1;
                     break;
                }
            }
        }
        else if(now == '\\'){
            putchar(now);
            next = getchar();
            putchar(next);
        }
        else{
            putchar(now);
        }
    }
    return 0;
}
 
int main(){
    pre_process();
    return 0;
}
